package com.wanxi.controller;

import com.wanxi.service.FrontCaseService;
import com.wanxi.entity.CaseQuery;
import com.wanxi.result.CommonResult;
import com.wanxi.vo.CaseVo;
import io.swagger.annotations.*;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@Api(description = "案例服务")
@RestController
@RequestMapping("/case")
public class FrontCaseController {

    @Autowired
    private FrontCaseService frontCaseService;

    @ApiOperation(value = "查询案例")
    @ApiResponses({
            @ApiResponse(code = 200, message = "OK", response = CaseVo.class, responseContainer = "List")
    })
    @GetMapping("/findCase")
    public CommonResult findCase(CaseQuery caseQuery) {
       return frontCaseService.findCase(caseQuery);
    }

}